!!!###!!!title=174-How to achieve a bar chart similar to the stacked column chart——VisActor/VChart FAQ documents!!!###!!!

How to achieve a bar chart similar to the stacked column chart?

Question Description

Seemly to https://www.visactor.io/vchart/demo/bar-chart/stack-column, how to make bars of different colors start from the y-axis zero scale and overlap with each other rather than stacking vertically?

Solution

The solution varies depending on the chart library being used. Based on the provided demo, you simply need to set the corresponding field to false in order to disable stacking.

Code Example

Result

Online demo:https://codesandbox.io/s/bar-chart-stack-false-cr6667

Quote

Stacked Bar Chart Demo:https://www.visactor.io/vchart/demo/bar-chart/stack-column

Bar Chart Tutorial:https://www.visactor.io/vchart/guide/tutorial_docs/Chart_Types/Bar

Related api:https://www.visactor.io/vchart/option/barChart#stack

github:https://github.com/VisActor/VChart